add_executable(WorkerToolTest test_worker_tool.cpp)

target_include_directories(WorkerToolTest PRIVATE
        ${COMMON_DIR}/include
        ${ROOT_DIR}/worker-tools/include
        ${ROOT_DIR}/common/thread-pool/include
        ${pybind11_INCLUDE_DIRS}
)

target_link_libraries(WorkerToolTest PRIVATE
        GTest::gtest
        pthread
        kvcache_service
        common_lib
        workertool_lib
)

if(DEVICE STREQUAL "GPU")
    target_include_directories(WorkerToolTest PRIVATE ${CUDA_INC_DIR})
    target_link_libraries(WorkerToolTest PRIVATE CUDA::cudart)
endif()

enable_testing()
add_test(NAME WorkerToolTest COMMAND WorkerToolTest)